package com.wen.commandMode;

public class Invoker {
    private Command command;

    public Command getCommand() {
        return command;
    }

    public void setCommand(Command command) {
        System.out.println("接收到命令");
        this.command = command;
    }

    /**
     * 执行命令
     */
    public void doSomething(){
        command.execute();
    }

}
